package fanshe4;

public class User {

    public User(String name, Integer age) {
        this.name = name;
        this.age = age;
    }

    public User(String name) {
        this.name = name;

    }
    public User() {
    }
    private String name="王芳";
    private Integer age=12;
    public String hover;

    @Override
    public String toString() {//使用tostring输出为数值 不改写tostring输出为地址
        return "User{" +
                "name='" + name + '\'' +
                ", age=" + age +
                '}';
    }
}
